using System;
using System.Collections.Generic;

namespace CGOnline.Server.Core
{
    [AttributeUsage(AttributeTargets.Class,Inherited=true, AllowMultiple=true)]
    public class StateAnnouncementAttribute:Attribute
    {
        public string StateGroup { set; get; }
        public string StateName { set; get; }
    }

    public class StateEventArgs:MyEventArgs
    {
        public string StateGroup { set; get; }
        public string OriginState { set; get; }
        public string NewState { set; get; }
    }

    public class StateException : Exception
    {
        public StateException():base() { }
        public StateException(string message) : base(message) { }

    }

    internal interface IState
    {
        Dictionary<string, List<string>> ListStateEnum();
        Dictionary<string,string> ListCurrentState();
        string GetState(string stateGroup);
        bool GoToState(string stateGroup,string state);
        event EventHandler<StateEventArgs> StateChanged;
    }

}